﻿using HECore.Common.Entitys;
using HECore.Tenant.Contract.Enums;
using Microsoft.EntityFrameworkCore;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace HECore.Tenant.Repository.Entites
{
    /// <summary>
    /// 角色表
    /// </summary>
    public class Role : EmployeeDeletionAudited
    {
        /// <summary>
        /// 角色ID
        /// </summary>
        [Key]
        [Comment("租户ID")]
        [Column(Order = 0)]
        public Guid Id { get; set; }

        /// <summary>
        /// 角色名称
        /// </summary>
        [Comment("角色名称")]
        [Required]
        [MaxLength(55)]
        [Column(Order = 1)]
        public string RoleName { get; set; }

        /// <summary>
        /// 角色描述
        /// </summary>
        [Comment("角色描述")]
        [MaxLength(200)]
        [Column(Order = 2)]
        public string RoleDescribe { get; set; }

        /// <summary>
        /// 是否系统角色
        /// </summary>
        [Comment("是否是系统角色")]
        public bool? IsSystemRole { get; set; }

        /// <summary>
        /// 系统角色类型
        /// </summary>
        [Comment("系统角色类型")]
        public SystemRoleTypeEnum? SystemRoleType { get; set; }
    }
}